package router

import (
	"github.com/gin-gonic/gin"
	"hosptial-record/api/patient"
	"hosptial-record/middlewares"
)

func InitPatientRouter(group *gin.RouterGroup) {
	route := group.Group("patient")
	route.Use(middlewares.JWTAuth())
	{
		route.GET("", patient.List)
		route.GET("/:id", patient.Detail)
		route.POST("", patient.Create)
		route.DELETE(":id", patient.Delete)
		route.PATCH("", patient.Update)
	}
}
